package com.llc.station.kcp.ui.core;/**
 * @Author 朱小杰
 * 时间 2017-09-11 .22:01
 * 说明 ...
 */

import com.llc.station.kcp.ui.core.component.PiceText;
import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.layout.*;
import javafx.stage.Stage;

public class Kcp extends Application {
    private int width = 600;//窗口宽度
    private int height = 950;//窗口高度

    private ComponentHelper helper;


    public static void main(String[] args) {
        System.setProperty("stationName","冠德石油方兴达油站");
        System.setProperty("road","1");
        System.setProperty("machine","1");
        launch(args);
    }

    @Override
    public void start(Stage primaryStage) {
        initSize();
        GridPane grid = new GridPane();
/*        grid.setVgap(10);
        grid.setHgap(10);*/
        grid.setGridLinesVisible(true);


        Pane titlePane = helper.getTitlePane();
        grid.add(titlePane,0,0,10,3);

        Pane contentPane = helper.getContentPane();
        grid.add(contentPane,0,3,10,4);

        Pane bottomPane = helper.getBottomPane();
        grid.add(bottomPane,0,8,10,3);

        Scene scene = new Scene(grid,width,height);
        scene.getStylesheets().add(getClass().getResource("test1.css").toExternalForm());
        primaryStage.setScene(scene);
        primaryStage.show();

    }







    /**
     * 初始化大小
     */
    private void initSize() {
        this.helper = new ComponentHelper(width,height);
    }


}
